﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Common
{
   public class Address
    {
       public int ID { get; set; }
       //Країна
       public string Country {get; set;}
       //Республіка
       public string Republic {get; set;}
       //Область
       public string Region {get; set;}
       //Район
       public string Area {get; set;}
       //Населений пункт
       public string Locality {get; set;}
       //Вулиця
       public string Street {get; set;}
       //Номер будинка
       public string HourseNumber {get; set;}
       //Номер квартири
       public string ApartmentsNumber {get; set;}
       //Телефон
       public string Phone {get; set;}
       //Факс
       public string Fax {get; set;}
       //Емейл
       public string Email { get; set; }

       public Dictionary<string, string> AdressFields { get; private set; }

       public Address() { }
       public Address(int id, string country, string republic, string region, string area, string locality, string street, string hourseNumber, string apartmentsNumber, string phone, string fax, string email) 
       {
           this.ID = id;
           this.Country = country;
           this.Republic = republic;
           this.Region = region;
           this.Area = area;
           this.Locality = locality;
           this.Street = street;
           this.HourseNumber = hourseNumber;
           this.ApartmentsNumber = apartmentsNumber;
           this.Phone = phone;
           this.Fax = fax;
           this.Email = email;

           AdressFields = new Dictionary<string, string>(11);
           
           AdressFields.Add("Country", Country);
           AdressFields.Add("Republic", Republic);
           AdressFields.Add("Region", Region);
           AdressFields.Add("Area", Area);
           AdressFields.Add("Locality", Locality);
           AdressFields.Add("Street", Street);
           AdressFields.Add("HourseNumber", HourseNumber);
           AdressFields.Add("ApartmentsNumber)", ApartmentsNumber);
           AdressFields.Add("Phone", Phone);
           AdressFields.Add("Fax", Fax);
           AdressFields.Add("Email", Email);
       }
    }
}
